<html>
<head><meta charset="utf-8"><title>maybe a bug? · t-compiler/rust-analyzer · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/index.html">t-compiler/rust-analyzer</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/maybe.20a.20bug.3F.html">maybe a bug?</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="187144585"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/maybe%20a%20bug%3F/near/187144585" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Charles Lew <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/maybe.20a.20bug.3F.html#187144585">(Feb 01 2020 at 03:30)</a>:</h4>
<p>Hello, i'm not sure whether others can reproduce this, but when writing a proc-macro crate (proc-macro = true) the type hints and auto completions all disappear.</p>



<a name="187155150"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/maybe%20a%20bug%3F/near/187155150" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> std::Veetaha <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/maybe.20a.20bug.3F.html#187155150">(Feb 01 2020 at 09:28)</a>:</h4>
<p>Hmm, can you open the lsp output? Because I caught a panic from <code>rust-analyzer</code>, though my build of <code>rust-analyzer</code> is not up-to-date.<br>
<a href="user_uploads/4715/RBpo-Su7KYzVz9ouLYm9qg-5/pasted_image.png" target="_blank" title="user_uploads/4715/RBpo-Su7KYzVz9ouLYm9qg-5/pasted_image.png">pasted image</a></p>
<div class="message_inline_image"><a href="user_uploads/4715/RBpo-Su7KYzVz9ouLYm9qg-5/pasted_image.png" target="_blank" title="pasted image"><img src="user_uploads/4715/RBpo-Su7KYzVz9ouLYm9qg-5/pasted_image.png"></a></div>



<a name="187155534"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/maybe%20a%20bug%3F/near/187155534" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> std::Veetaha <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/maybe.20a.20bug.3F.html#187155534">(Feb 01 2020 at 09:42)</a>:</h4>
<p>Hmm, its hard to tell what causes it, here is the full backtrace:</p>
<div class="codehilite"><pre><span></span>thread &#39;&lt;unnamed&gt;&#39; panicked at &#39;index out of bounds: the len is 1 but the index is 2&#39;, /rustc/73528e339aae0f17a15ffa49a8ac608f50c6cf14/src/libcore/slice/mod.rs:2796:10
stack backtrace:
   0: backtrace::backtrace::libunwind::trace
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.40/src/backtrace/libunwind.rs:88
   1: backtrace::backtrace::trace_unsynchronized
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.40/src/backtrace/mod.rs:66
   2: std::sys_common::backtrace::_print_fmt
             at src/libstd/sys_common/backtrace.rs:77
   3: &lt;std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display&gt;::fmt
             at src/libstd/sys_common/backtrace.rs:61
   4: core::fmt::write
             at src/libcore/fmt/mod.rs:1028
   5: std::io::Write::write_fmt
             at src/libstd/io/mod.rs:1412
   6: std::sys_common::backtrace::_print
             at src/libstd/sys_common/backtrace.rs:65
   7: std::sys_common::backtrace::print
             at src/libstd/sys_common/backtrace.rs:50
   8: std::panicking::default_hook::{{closure}}
             at src/libstd/panicking.rs:188
   9: std::panicking::default_hook
             at src/libstd/panicking.rs:205
  10: std::panicking::rust_panic_with_hook
             at src/libstd/panicking.rs:464
  11: std::panicking::continue_panic_fmt
             at src/libstd/panicking.rs:373
  12: rust_begin_unwind
             at src/libstd/panicking.rs:302
  13: core::panicking::panic_fmt
             at src/libcore/panicking.rs:139
  14: core::panicking::panic_bounds_check
             at src/libcore/panicking.rs:96
  15: ra_ide::line_index::LineIndex::offset
  16: ra_lsp_server::main_loop::handlers::handle_code_action
  17: &lt;F as threadpool::FnBox&gt;::call_box
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
</pre></div>



<a name="187202766"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/maybe%20a%20bug%3F/near/187202766" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Charles Lew <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/maybe.20a.20bug.3F.html#187202766">(Feb 02 2020 at 12:01)</a>:</h4>
<p>Hi, i think the problem here is a little flaky. i cannot always reproduce the main issue. However i can always reproduce a small fraction of it. So i created an issue for the separate smaller issue. <a href="https://github.com/rust-analyzer/rust-analyzer/issues/2984" target="_blank" title="https://github.com/rust-analyzer/rust-analyzer/issues/2984">https://github.com/rust-analyzer/rust-analyzer/issues/2984</a></p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>